package com.du.enums;

import lombok.Getter;

@Getter
public enum ExceptionEnum {
    PASSWORD_ERROR(10,"密码错误！"),
    USERNAME_NOT_EXIST(9,"用户名不存在！"),
    VALIDATE_CODE(8,"验证码错误！"),
    REQUEST_PARAMS(7,"请求参数不合法!"),
    REGISTER_FAILURE(6,"注册账号失败！"),
    SEND_SMS(5,"手机号码格式不合法！"),
    CHECK_USERNAME(4,"用户名已存在！"),
    ITEM_ADD_FAILURE(14,"商品添加失败！"),
    PIC_OVERSIZE(15,"图片过大！请重新上传!"),
    PIC_TYPE_ERROR(16,"不支持的图片类型!"),
    PIC_CONTEXT_ERROR(17,"图片已损坏！"),
    ITEM_DELETE_FAILURE(18,"删除商品信息失败！"),
    ITEM_UPDATEPAGELOADDING_FAILURE(24,"加载商品修改页面失败!"),
    ITEM_UPDATE_FAILURE(25,"修改商品信息失败！")
    ;

    private Integer code;
    private String msg;

    ExceptionEnum(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }
}
